Trusted Platform Module (TPM)

From RidgeRun Developer Wiki




NVIDIA partner logo NXP partner logo






Trusted Platform Module

The Trusted Platform Module, more commonly known as TPM, is a type of chip that helps to enhance the security of a system. A TPM is a is a secure crypto-processor that includes physical security measures so that the chip can be tampered with and the security features provided by the TPM are not affected.

Some of the uses of a TPM are the following:

  • Generating and storing cryptographic keys.
  • Device authentication with the TPM's RSA key, that is burned into the chip.
  • Help ensure platform integrity by taking and storing security measurements of the boot process.

During the boot process, the boot code can be measured to ensure the integrity of the system, which can be done by using the TPM key. In this case, "measuring" refers to the current object being analyzed in the chain of trust, computing the hash of the next object in the chain and stores it. These hashes can be retrieved later to know exactly which objects were loaded, this technique is known as Measured Boot. It is important to know that measured boot does not stop a system from booting in the same way that secure boot does. The measured hashes are stores in the TPM to ensure that they would not be modified and the information will be correct if they need to be retrieved later.

Fig 1. Measured Boot process. Extracted from link

Here the concept of attestation comes into play. You can define attestation as proving that something exists or happened by providing valid evidence, in the context of embedded system security attestation would refer to boot logs that prove the configuration state of a system.

While discrete TPMs are the most common and often considered the most secure, there are other implementations that comply with the Trusted Computing Group (TCG) specification. The current types of TPM implementations are the following:

  • Discrete TPMs are dedicated chips that implement TPM functionality in their own tamper resistant semiconductor package. They are the most secure, certified to FIPS-140 with level 3 physical security resistance to attack versus routines implemented in software, and their packages are required to implement some tamper resistance.
  • Integrated TPMs are contained in another chip. While they use hardware that resists software bugs, they are not required to implement tamper resistance.
  • Firmware TPMs (fTPMs) are firmware-based solutions that run in a CPU's trusted execution environment.
  • Virtual TPMs (vTPMs) are provided by and rely on hypervisors in isolated execution environments that are hidden from the software running inside virtual machines. They can provide a security level comparable to a firmware TPM.
  • Software TPMs are software emulators of TPMs that run with similar protection as a regular program gets within an operating system. They depend entirely on the environment that they run in, so they provide no more security than what can be provided by the normal execution environment. They are useful for development purposes.

Additionally, the TCG provides the following table to compare the different TPM implementations, obtained from the following document:

TPM Implementations
Trust Element Security Levels Security Features Relative Cost Typical Application
Discrete TPM Highest Tamper resistant hardware $$$ Critical Systems
Integrated TPM Higher Hardware $$ Gateways
Firmware TPM High TEE $ Entertainment systems
Software TPM N/A N/A ¢¢ Testing and prototyping
Virtual TPM High Hypervisor ¢ Cloud environment